/**
 * 高德地图功能封装
 * */
import axios from "axios";

export class GaoDeTool {
  // 高德地图key
  private key = "";

  /**
   * ip转换为地理位置信息
   * @param {string} ip - ipv4地址
   * */
  async transformIp(ip: string) {
    return axios.get(`https://restapi.amap.com/v3/ip?key=${this.key}&ip=${ip}`);
  }
}
